Skip to content

feat: route code execution per agent profile - #416

Merged
danny-avila merged 5 commits into
mainfrom
danny-avila/per-agent-execution-profiles
Aug 15, 2026
Merged

feat: route code execution per agent profile#416
danny-avila merged 5 commits into
mainfrom
danny-avila/per-agent-execution-profiles

Conversation

@danny-avila

@danny-avila danny-avila commented Aug 14, 2026

Copy link
Copy Markdown
Owner

Summary

  • let Code, Bash, Python PTC, and Bash PTC select a trusted Code API base URL and expected execution profile per tool factory
  • assert the selected profile with X-CodeAPI-Expected-Profile on initial and continuation requests
  • prefer per-agent runtime affinity context and prevent explicit default-profile tools from inheriting graph-wide stateful hints
  • partition Graph code-session IDs and file refs by a trusted per-agent key while preserving the legacy shared stateless partition
  • apply the same partition to direct, event-driven, eager, handoff, and child-graph tool execution

Why

This is the Agents transport and session-isolation layer for AI-1650: stateless agents use the default HTTP/libkrun profile, while stateful agents use the Lambda MicroVM profile, including mixed-agent graphs. Session refs from one profile are never injected into another.

Dependencies

Validation

  • npm run build
  • 75 focused Code API transport and ToolNode session tests
  • focused ESLint with zero errors
  • exact-head CI running on the rebased branch

@danny-avila

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 6cdd711e69

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/stream.ts
Comment thread src/graphs/Graph.ts
@danny-avila

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: f161ea7a4f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/utils/toolSessions.ts Outdated
Comment thread src/tools/CodeExecutor.ts Outdated
Comment thread src/tools/CodeExecutor.ts Outdated
@danny-avila

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Already looking forward to the next diff.

Reviewed commit: 9058e8dc4f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@danny-avila

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Another round soon, please!

Reviewed commit: 339a108da1

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@danny-avila
danny-avila marked this pull request as ready for review August 14, 2026 21:57
@danny-avila
danny-avila merged commit 320deb8 into main Aug 15, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant